Skip to content

Fix for AppDomain creation should honor runsettings#427

Merged
jayaranigarg merged 3 commits into
microsoft:masterfrom
jayaranigarg:appdomainfix
May 24, 2018
Merged

Fix for AppDomain creation should honor runsettings#427
jayaranigarg merged 3 commits into
microsoft:masterfrom
jayaranigarg:appdomainfix

Conversation

@jayaranigarg

Copy link
Copy Markdown
Member

No description provided.

@jayaranigarg jayaranigarg requested a review from smadala May 24, 2018 08:37

@nigurr nigurr left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please do add test for enabled case too. thanks

if (this.runSettings != null && MSTestAdapterSettings.IsAppDomainCreationDisabled(this.runSettings.SettingsXml))
{
this.isAppDomainCreationDisabled = true;
return;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change the function name to IsAppDomainCreationDisabledInRunSettings make return type bool. or assign value of this.runSettings != null && MSTestAdapterSettings.IsAppDomainCreationDisabled(this.runSettings.SettingsXml) to isAppDomainCreationDisabled in .ctor and remove this function.

var mockRunSettings = new Mock<IRunSettings>();
mockRunSettings.Setup(rs => rs.SettingsXml).Returns(runSettingxml);

Mock<TestSourceHost> sourceHost = new Mock<TestSourceHost>(location, mockRunSettings.Object, null) { CallBase = true };

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: testSourceHost

@jayaranigarg

Copy link
Copy Markdown
Member Author

@dotnet-bot Test Windows / Release Build please

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants